When to use shallow copy vs deep copy